package com.huluspace.learnhub.repository;

import com.huluspace.learnhub.model.Content;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.stereotype.Repository;

@Repository
public interface ContentRepository extends JpaRepository<Content, Long> {

  Page<Content> findByType(String type, Pageable pageable);

  Page<Content> findByTypeAndTitleContaining(String type, String keyword, Pageable pageable);
}
